package com.boot.wt.controller;

import com.boot.wt.scheduled.WeatherScheduled;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequiredArgsConstructor
public class WeatherController {

    private  WeatherScheduled weatherScheduled;

    public WeatherController(WeatherScheduled weatherScheduled) {
        this.weatherScheduled = weatherScheduled;
    }

    @GetMapping("/")
    public String demo() {
        weatherScheduled.weather();
        return "发送成功";
    }
}
